TlsCertificate.this

Creates a #GTlsCertificate from the data in @file.

As of 2.72, if the filename ends in .p12 or .pfx the data is loaded by g_tls_certificate_new_from_pkcs12() otherwise it is loaded by g_tls_certificate_new_from_pem(). See those functions for exact details.

If @file cannot be read or parsed, the function will return %NULL and set @error.

Parameters

file string

file containing a certificate to import

Return Value

the new certificate, or %NULL on error

Throws

GException on failure. ConstructionException GTK+ fails to create the object.

Meta

Since

2.28